package com.ck.retry.controller;

import com.ck.retry.service.RetryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ck
 * @date 2024/1/8 9:42
 */
@RestController
@RequestMapping("/retry")
public class RetryController {

    @Autowired
    RetryService retryService;

    @GetMapping("/testRetry")
    public String testRetry() throws Exception {
        int code=0;
        int result = retryService.retryTest(code);
        return "result:"+result;
    }
}
